package com.mallcloud.mall.common.core.constant.enums.mall;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.RequiredArgsConstructor;

import java.util.Arrays;

/**
 * 积分商品库存记录
 */
@Getter
@AllArgsConstructor
public enum FloorEnum {

	//字典
	REDEEM_STATUS("REDEEM_STATUS", "积分商品库存记录字典"),
	;

	private final String type;
	private final String description;

	@Getter
	@RequiredArgsConstructor
	public enum FloorStatusEnum {
		Y("启用"),
		N("停用"),
		;
		private final String description;

		public static String getDecs(String status) {
			return Arrays.stream(values()).filter(x -> x.name().equals(status)).findFirst().get().getDescription();
		}
	}

}
